<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div></div>
    <div></div>
    <div></div>


    <script>
        // https://blog.51cto.com/u_15080016/4524390
        // 1.数组的合并
        const kuaizi = ['王大力', '肖央']
        const fenghuang = ['曾毅', '玲花']
        // const arr = kuaizi.concat(fenghuang)

        const arr = [...kuaizi, ...fenghuang]
        console.log(arr)

        // 2.数组的克隆
        const sanzhihua = ['E', 'G', 'M']
        const sanyecao = [...sanzhihua]
        console.log(sanyecao)

        // 3.将伪数组转为真正的数组
        const divs = document.querySelectorAll('div') //对象
        const divArr = [...divs] //数组 方便使用数组方法
        console.log(divs)
        console.log(divArr)


        let args = {
            x:1,
            y:2,
            z:3,
            point:{}
        }
        function test (args) {
            console.log('args',args)
            const {point, ...others} = args
            console.log(point, others)
        }
        test(args)
    </script>
</body>
</html>